package com.example.demo.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.demo.entity.EavAttribute;
import com.example.demo.mapper.EavAttributeMapper;
import com.example.demo.service.EavAttributeService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class EavAttributeServiceImpl extends ServiceImpl<EavAttributeMapper, EavAttribute> implements EavAttributeService {
    @Override
    public List<EavAttribute> selectByTypeId(Long typeId) {
        LambdaQueryWrapper<EavAttribute> queryWrapper = new LambdaQueryWrapper<>();
        queryWrapper.eq(EavAttribute::getEntityTypeId, typeId);
        return list(queryWrapper);
    }
}
